@extends("/paging_template")
@import com.mgfireworks.mgplatform.mgadmin.user.model.User
@args List<User> userList
<div id="datatable-responsive_wrapper" class="dataTables_wrapper dt-bootstrap no-footer">
   		<div class="x_panel">
   			<div class="x_title">
              	<h2>用户列表</h2>
           		<ul class="nav navbar-right panel_toolbox">
               		<li><a class="collapse-link"><i class="fa fa-chevron-up"></i></a></li>
           		</ul>
              <div class="clearfix"></div>
            </div>
            <div class="x_content" style="display: block;">
	           	<div class="row form-horizontal">
	           		<div class="col-sm-4 form-group">
                        <label class="control-label col-sm-3">用户编号</label>
                        <div class="col-sm-9">
                          <input type="text" class="form-control" name="userId" value="@val("userId")" placeholder="用户编号">
                        </div>
                    </div>
	           		<div class="col-sm-4 form-group">
                        <label class="control-label col-sm-3">用户账号</label>
                        <div class="col-sm-9">
                          <input type="text" class="form-control" name="userAccount" value="@val("userAccount")" placeholder="用户账号">
                        </div>
                    </div>
	           		<div class="col-sm-4 form-group">
                        <label class="control-label col-sm-3">用户名称</label>
                        <div class="col-sm-9">
                          <input type="text" class="form-control" name="userName" value="@val("userName")" placeholder="用户名称">
                        </div>
                    </div>
	           		<div class="col-sm-4 form-group">
                        <label class="control-label col-sm-3">用户密码</label>
                        <div class="col-sm-9">
                          <input type="text" class="form-control" name="userPwd" value="@val("userPwd")" placeholder="用户密码">
                        </div>
                    </div>
	           		<div class="col-sm-4 form-group">
                        <label class="control-label col-sm-3">所属机构</label>
                        <div class="col-sm-9">
                          <input type="text" class="form-control" name="orgId" value="@val("orgId")" placeholder="所属机构">
                        </div>
                    </div>
	           		<div class="col-sm-4 form-group">
                        <label class="control-label col-sm-3">用户角色</label>
                        <div class="col-sm-9">
                          <input type="text" class="form-control" name="userRole" value="@val("userRole")" placeholder="用户角色">
                        </div>
                    </div>
	           		<div class="col-sm-4 form-group">
                        <label class="control-label col-sm-3">最后登录时间</label>
                        <div class="col-sm-9">
                          <input type="text" class="form-control" name="lastLoginTime" value="@val("lastLoginTime")" placeholder="最后登录时间">
                        </div>
                    </div>
	           		<div class="col-sm-4 form-group">
                        <label class="control-label col-sm-3">最后登录IP</label>
                        <div class="col-sm-9">
                          <input type="text" class="form-control" name="lastLoginIp" value="@val("lastLoginIp")" placeholder="最后登录IP">
                        </div>
                    </div>
					<div class="col-sm-4 form-group">
						<button type="submit" class="form-control btn btn-primary">查询</button>
					</div>
				</div>
	            <div id="div_list_toolbar" class="btn-group">
			    	<a href="@url("/user/add.html")" class="btn btn-success" type="button"><i class="fa fa-plus"></i>添加</a>
			    	<a href="@url("/user/edit.html?userId={0}")" class="btn btn-success" type="button"><i class="fa fa-pencil"></i>修改</a>
			    	<a href="@url("/user/del.json?userId={0}")" class="btn btn-success" type="button"><i class="fa fa-times"></i>删除</a>
		     	</div>
	            <div class="clearfix"></div>
         	</div>
       </div>

	<div class="row">
		<div class="col-sm-12">
			<table id="datatable" class="table table-striped table-bordered dataTable no-footer" role="grid" aria-describedby="datatable_info">
			  <thead>
			    <tr role="row">
			    	<th class="td_row_id">
					</th>
				    <th>用户编号</th>
				    <th>用户账号</th>
				    <th>用户名称</th>
				    <th>用户密码</th>
				    <th>所属机构</th>
				    <th>用户角色</th>
				    <th>最后登录时间</th>
				    <th>最后登录IP</th>
			    </tr>
			  </thead>
			  <tbody>
			  @if(userList){
			  @{int i=0;}
			  @for(User p : userList){
			   <tr role="row" class="@(i%2==0?"odd":"event")">
			   @{i++;}
			   	  <td class="td_row_id">
				   	  <div class="checkbox">
                        <label>
                          <div class="iradio_flat-green" style="position: relative;"><input type="checkbox" class="flat" name="__recordId" value="@p.getUserId()" style="position: absolute; opacity: 0;"><ins class="iCheck-helper" style="position: absolute; top: 0%; left: 0%; display: block; width: 100%; height: 100%; margin: 0px; padding: 0px; border: 0px; opacity: 0; background: rgb(255, 255, 255);"></ins></div>
                        </label>
                      </div>
			   	  </td>
				  <td>@p.getUserId()</td>
				  <td>@p.getUserAccount()</td>
				  <td>@p.getUserName()</td>
				  <td>@p.getUserPwd()</td>
				  <td>@p.getOrgId()</td>
				  <td>@p.getUserRole()</td>
				  <td>@p.getLastLoginTime()</td>
				  <td>@p.getLastLoginIp()</td>
			    </tr>
			   }
			 }else{
			   <tr role="row">
			      <td colspan="9">暂无数据<i class="fa fa-exclamation-circle"></i></td>
			   </tr>
			 }
			    </tbody>
			</table>	
		</div>
	</div>
	
</div>